﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.ComponentModel.DataAnnotations;
using Sita.Entities.MetaData.CustomAttributes;

namespace Sita.Entities.MetaData
{
    public class Vehicle
    {
        [ScaffoldColumn(false)]
        public object VehicleID { get; set; }

        [ScaffoldColumn(false)]
        public object BusinessUnitID { get; set; }

        [LocalizedDisplayName("Owner", ResourceType = typeof(Resources.Vehicle))]
        [DataType(DataType.Text)]
        public object CustomerID { get; set; }

        [LocalizedDisplayName("Type", ResourceType = typeof(Resources.Vehicle))]
        [DataType(DataType.Text)]
        public object VehicleTypeID { get; set; }

        [LocalizedDisplayName("Brand", ResourceType = typeof(Resources.Vehicle))]
        [DataType(DataType.Text)]
        public object BrandID { get; set; }

        [LocalizedDisplayName("Model", ResourceType = typeof(Resources.Vehicle))]
        [StringLength(50, ErrorMessageResourceType = typeof(Resources.Vehicle), ErrorMessageResourceName = "ModelMaxLength")]
        [DataType(DataType.Text)]
        public object ModelName { get; set; }

        [LocalizedDisplayName("LicencePlate", ResourceType = typeof(Resources.Vehicle))]
        [StringLength(50, ErrorMessageResourceType = typeof(Resources.Vehicle), ErrorMessageResourceName = "LicencePlateMaxLength")]
        [DataType(DataType.Text)]
        public object LicencePlate { get; set; }

        [LocalizedDisplayName("EngineNumber", ResourceType = typeof(Resources.Vehicle))]
        [StringLength(50, ErrorMessageResourceType = typeof(Resources.Vehicle), ErrorMessageResourceName = "EngineNumberMaxLength")]
        [DataType(DataType.Text)]
        public object EngineNumber { get; set; }

        [LocalizedDisplayName("SerialNumber", ResourceType = typeof(Resources.Vehicle))]
        [StringLength(50, ErrorMessageResourceType = typeof(Resources.Vehicle), ErrorMessageResourceName = "SerialNumberMaxLength")]
        [DataType(DataType.Text)]
        public object SerialNumber { get; set; }

        [LocalizedDisplayName("PurchaseDate", ResourceType = typeof(Resources.Vehicle))]
        [DataType(DataType.Date)]
        //[Required(ErrorMessageResourceType = typeof(Resources.DriveTestView), ErrorMessageResourceName = "DateFromRequired")]
        public object PurchaseDate { get; set; }
    }
}
